package shotgun.my.sweetutil.data;

import java.util.function.Consumer;

/**
 * 数据同步处理抽象类
 **/
public abstract class DataSyncDeal<E, P> {

    protected abstract E getSourceData(P param);

    public void syncOne(P param, Consumer<E> deal) {
        deal.accept(getSourceData(param));
    }

}
